﻿@model Vnsf.WebHost.Models.GrantBindingModel

@{
    ViewBag.Title = "Create";
}

<h2>Create</h2>

@using (Html.BeginForm())
{
    @Html.AntiForgeryToken()

    <div class="form-horizontal">
        <h4>GrantBindingModel</h4>
        <hr />
        @Html.ValidationSummary(true)
        <div class="form-group">
            @Html.LabelFor(model => model.Grant.Code, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.Grant.Code)
                @Html.ValidationMessageFor(model => model.Grant.Code)
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.Grant.Name, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.Grant.Name)
                @Html.ValidationMessageFor(model => model.Grant.Name)
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.Grant.Description, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.Grant.Description)
                @Html.ValidationMessageFor(model => model.Grant.Description)
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.Grant.Objective, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.Grant.Objective)
                @Html.ValidationMessageFor(model => model.Grant.Objective)
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.Grant.MaxDuration, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.Grant.MaxDuration)
                @Html.ValidationMessageFor(model => model.Grant.MaxDuration)
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.Grant.Total, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.Grant.Total)
                @Html.ValidationMessageFor(model => model.Grant.Total)
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.Grant.MaxAward, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.Grant.MaxAward)
                @Html.ValidationMessageFor(model => model.Grant.MaxAward)
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.Grant.Agency, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.DropDownList("Grant.AgencyId", Model.Agencies)
                @Html.ValidationMessageFor(model => model.Grant.AgencyId)
            </div>
        </div>

        <div class="form-group">
            <div class="col-md-offset-2 col-md-10">
                <input type="submit" value="Create" class="btn btn-default" />
            </div>
        </div>
    </div>
}

<div>
    @Html.ActionLink("Back to List", "Index")
</div>
